package com.hxzy.entity;

import com.alibaba.fastjson.annotation.JSONField;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @Description:
 * @Author: ykj
 * @Date: 2022/2/24 11:51
 */
public class UserInfo {
    private Integer id;

    @NotBlank(message = "账户不能为空")
    private String loginName;

    @NotBlank(message = "密码不能为空")
    @Length(min=4,max = 30,message = "密码长度必须4-30位之间")
    @JSONField(serialize = false)
    private String LoginPwd;

    @NotNull(message = "状态不能为空")
    private Integer status;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getLoginName() {
        return loginName;
    }

    public void setLoginName(String loginName) {
        this.loginName = loginName;
    }

    public String getLoginPwd() {
        return LoginPwd;
    }

    public void setLoginPwd(String loginPwd) {
        LoginPwd = loginPwd;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    @Override
    public String toString() {
        return "UserInfo{" +
                "id=" + id +
                ", loginName='" + loginName + '\'' +
                ", LoginPwd='" + LoginPwd + '\'' +
                ", status=" + status +
                '}';
    }
}
